| Conditions | 2 |
| Paths | 2 |
| Total Lines | 20 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | var deptData = null; |
||
| 44 | function initPage() |
||
| 45 | { |
||
| 46 | var id = getParameterByName('id'); |
||
| 47 | if(id === null) |
||
| 48 | { |
||
| 49 | $.ajax({ |
||
| 50 | url: 'api/v1/departments?$top=1', |
||
| 51 | type: 'GET', |
||
| 52 | dataType: 'json', |
||
| 53 | complete: getDepartmentDone}); |
||
| 54 | } |
||
| 55 | else |
||
| 56 | { |
||
| 57 | $.ajax({ |
||
| 58 | url: 'api/v1/departments/'+id, |
||
| 59 | type: 'GET', |
||
| 60 | dataType: 'json', |
||
| 61 | complete: getDepartmentDone}); |
||
| 62 | } |
||
| 63 | } |
||
| 64 | |||
| 66 |